package team;

import java.util.Random;

public class TestTeam {
    public static void main(String[] args) {
        // 创建1000个队员的信息（示例中只创建了5个，实际应用中应创建1000个）
        TeamMember[] teamMembers = new TeamMember[1000];
        Random random = new Random();
        for (int i = 0; i < 1000; i++) {
            // 假设每个队员的成绩是随机生成的
            double[] scores = new double[5];
            for (int j = 0; j < scores.length; j++) {
                scores[j] = random.nextDouble() * 100; // 随机生成0到100之间的成绩
            }
            teamMembers[i] = new TeamMember("Member" + (i + 1), 20 + i % 10, scores); // 假设年龄在20到29之间
        }

        // 创建球队对象
        Team team = new Team("DreamTeam", teamMembers);

        // 输出平均成绩最好的前50名队员的信息
        team.printTop50Members();
    }
}
